﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;
using System.Data.Entity;
using System.Web;
using BAL.Infrastructure;
using BAL.Interfaces;
using DAL;
using DAL.Infrastructure;
using DAL.Interfaces;
using DAL.Models;

namespace BAL 
{

    public class BALSocios : ServiceBase<Socios>, ISociosService
    {

        public BALSocios(IRepository<Socios> repository, IApplicationContext context) 
            : base(repository, context)
        {

        }

        public override IQueryable<Socios> GetAllValidados()
        {
            try
            {
                return _repository.GetAllValidados().Include(m => m.Prestamos).Include(m => m.Reservaciones).Include(m => m.UsuarioSocios);
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
    }
}
